import request from '@/api/request';
const mockUrl = (path) => {
    return 'http://127.0.0.1:4523/m1/3058855-0-default' + path;
};
const prefixUrl = (path) => {
    return '/api' + path;
};
export const getActiveDevices = () => {
    const url = prefixUrl('/api/activeDevices');
    return request.get(url);
};
export const userLogin = (data) => {
    const url = prefixUrl('/user/login');
    return request.post(url, data);
};
export const getHistoryHr = (params) => {
    const url = prefixUrl('/api/history/hr');
    return request.get(url, { params });
};
export const getHistorySpo2 = (params) => {
    const url = prefixUrl('/api/history/spo2');
    return request.get(url, { params });
};
export const getHistoryResp = (params) => {
    const url = prefixUrl('/api/history/resp');
    return request.get(url, { params });
};
export const getHistoryNibp = (params) => {
    const url = prefixUrl('/api/history/nibp');
    return request.get(url, { params });
};
export const getHistoryTemp = (params) => {
    const url = prefixUrl('/api/history/temp');
    return request.get(url, { params });
};
